﻿//This is the driver of the program


function view_onOpen() {
/*
  var ringList=new Array();
  //create the default rings
	ringList[0]="24hr";
  ringList[1]="month";
  ringList[2]="year";
	loadRings(ringList);
*/
	ring2.colorMultiply = '#8D38C9';
}

//take the list of rings as parameter
function loadRings(ringList) {
  var i=0;
	for (i=0; i<ringList.length; i++)
	{
		r=new ring;
    r.name=ringList[i];
		view.alert(r.name);
	}
}


function multiplyColor() {
  var source = event.srcElement;

  if (source.value) {
    switch (source.name) {
      case 'greenButton':
        basicRing.colorMultiply = '#00FF00';
        break;
      case 'blueButton':
        basicRing.colorMultiply = '#0000FF';
        break;
    }
  }
}

function halfOpacity(){
	clock.opacity = .5 * gddElementMaxOpacity;
}

function fullOpacity(){
	clock.opacity = gddElementMaxOpacity;
}

